<!-- body -->
  <div id="hover-tip"></div>
  <div class="container nav-margin-top">
    <ol class="breadcrumb">
      <li><a href="/nsbbs/">首页</a></li>
      <li><a href="zone.php">版面目录</a></li>
      <li class="active"><?php echo htmlspecialchars($isExist[0]['name'])?></li>
    </ol>
    <!-- 热门版面 -->
    <div class="list-item item-lg">
      <div class="list-title list-lg hand">热门版面<b class="r pull"></b></div>
      <div class="list-content container-fluid">
<?php if($data_arr){ 
    $i = 0;
    foreach($data_arr as $item){ 
      if($i++ == 3){
      break;
    }
?>
        <div class="row module-info">
          <a href="module.php?mid=<?php echo $item['id']?>" class="link"></a>
          <div class="col-sm-6">
            <div class="module-title">
              <b class="hot"></b>
              <span class="tt"><?php echo htmlspecialchars($item['name'])?></span>
            </div>
            <div class="module-label"><?php echo htmlspecialchars($item['info'])?></div>
            <div class="module-main">
              <span>今日：<?php echo $item['today']?></span>
              <span>主题：<?php echo $item['main']?></span>
              <span>帖数：<?php echo $item['all']?></span>
            </div>
            <div class="module-manager">
              <span>版务：</span>
              <?php if($item['manager']){
                foreach($item['manager'] as $man_item){
              ?>
                <a <?php echo $target?> href="userinfo.php?uid=<?php echo $man_item['id']?>"><?php echo htmlspecialchars($man_item['user'])?></a>
              <?php }
                }else{ ?>
                <span class="icolor">暂无版务</span>
              <?php } ?>
            </div>
          </div>
          <div class="col-sm-6">
            <div class="content-push clearfix">
              <?php if($item['content']){ ?>
              <a <?php echo $target?> href="userinfo.php?uid=<?php echo $item['content']['user_info']['id']?>" class="l">
                <img src="<?php echo PHOTO_PATH.$item['content']['user_info']['photo']?>">
              </a>
              <div class="l content">
                <div class="content-title">
                  <a href="details.php?cid=<?php echo $item['content']['id']?>"><?php echo htmlspecialchars($item['content']['title'])?></a>
                </div>
                <div class="content-time">
                  <span>
                  <?php echo htmlspecialchars($item['content']['user_info']['user'])?>
                  <?php echo $item['content']['time']?>
                  </span>
                </div>
              </div>
              <?php }else{ ?>
                <span class="icolor">暂无动态</span>
            <?php } ?>
            </div>
          </div>
          
        </div>
    <?php } 
    }else{ ?>
        <div class="no-cont">
            暂无版面
        </div>
<?php } ?>

      </div>
    </div>
  
    <!-- 全部版面 -->
    <div class="list-item item-lg">
      <div class="list-title-all list-lg">全部版面</div>
      <div class="list-content-all">
    <!-- 版面分组 -->
<?php foreach($kind as $kind_item){?>
        <div class="list-item item-sm">
          <div class="list-title hand list-sm">
            <?php echo htmlspecialchars($kind_item['name'])?>
            <b class="r pull pull-sm"></b>
          </div>
          <div class="list-content container-fluid">
            <!-- 版面里的子版 -->
<?php if($data_arr){ 
    foreach($data_arr as $item2){ 
      if($item2['kid'] != $kind_item['id']){
        continue;
      }
      $ishave = true;
?>
        <div class="row module-info">
          <a href="module.php?mid=<?php echo $item2['id']?>" class="link"></a>
          <div class="col-sm-6">
            <div class="module-title">
            <?php if($user_data){?>
              <b class="collect hand<?php echo $item2['collect']?>" id="<?php echo $item2['id']?>"></b>
            <?php } ?>
              <span class="tt"><?php echo htmlspecialchars($item2['name'])?></span>
            </div>
            <div class="module-label"><?php echo htmlspecialchars($item2['info'])?></div>
            <div class="module-main">
              <span>今日：<?php echo $item2['today']?></span>
              <span>主题：<?php echo $item2['main']?></span>
              <span>帖数：<?php echo $item2['all']?></span>
            </div>
            <div class="module-manager">
              <span>版务：</span>
              <?php if($item2['manager']){
                foreach($item2['manager'] as $man_item2){
              ?>
                <a <?php echo $target?> href="userinfo.php?uid=<?php echo $man_item2['id']?>"><?php echo htmlspecialchars($man_item2['user'])?></a>
              <?php }
                }else{ ?>
                <span class="icolor">暂无版务</span>
              <?php } ?>
            </div>
          </div>
          <div class="col-sm-6">
            <div class="content-push clearfix">
              <?php if($item2['content']){ ?>
              <a <?php echo $target?> href="userinfo.php?uid=<?php echo $item2['content']['user_info']['id']?>" class="l">
                <img src="<?php echo PHOTO_PATH.$item2['content']['user_info']['photo']?>">
              </a>
              <div class="l content">
                <div class="content-title">
                  <a href="details.php?cid=<?php echo $item2['content']['id']?>"><?php echo htmlspecialchars($item2['content']['title'])?></a>
                </div>
                <div class="content-time">
                  <span>
                  <?php echo htmlspecialchars($item2['content']['user_info']['user'])?>
                  <?php echo $item2['content']['time']?>
                  </span>
                </div>
              </div>
              <?php }else{ ?>
                <span class="icolor">暂无动态</span>
            <?php } ?>
            </div>
          </div>
        </div>
    <?php }
        if(!$ishave){  ?>
        <div class="no-cont">
            暂无版面
        </div>
<?php   } 
    }else{ ?>
        <div class="no-cont">
            暂无版面
        </div>
<?php } ?>
    
          </div>
        </div>
<?php } ?>
        

      </div>
    </div>

  </div>
<script src="public/js/jquery.min.js"></script>
<script src="public/js/my-bootstrap.min.js"></script>
<script async src="public/js/list.all.js"></script>
